function input_text1(text_str) {
    var key = null;
    var change_1 = null;
    var change_2 = null;
    for (let i = 0; i < text_str.length; i++) {
        key = desc(text_str[i], pkg('com.google.android.inputmethod.latin')).getOneNodeInfo(500);
        if (key) {
            key.click();
        }
        sleep(500);
    }
    return true;
}

function input_text(text_str) {
    var key = null;
    var change_1 = null;
    var change_2 = null;
    for (let i = 0; i < text_str.length; i++) {
        if (Number.isFinite(text_str[i] % 65535) || text_str[i] === '@' || text_str[i] === '/') {
            change_1 = desc('Symbol keyboard').getOneNodeInfo(500);
            if (change_1) {
                change_1.click();
                sleep(500);
                if (text_str[i] === '/') {
                    var a = desc('forward slash', pkg('com.google.android.inputmethod.latin')).getOneNodeInfo(400);
                    if (a) {
                        a.click();
                    }
                }

            }
        } else {
            change_2 = desc('Letter keyboard').getOneNodeInfo(400);
            if (change_2) {
                change_2.click();
            }
        }
        key = desc(text_str[i], pkg('com.google.android.inputmethod.latin')).getOneNodeInfo(400);
        if (key) {
            key.click();
        }
        sleep(500);
    }
    return true;
}

